package top.stmo.spring.ioc.test2;


import org.springframework.context.support.ClassPathXmlApplicationContext;
import top.stmo.spring.ioc.test2.dao.BookDao;
import top.stmo.spring.ioc.test2.service.BookService;



/**
 *   -------------------------注解开发--------------------------
 *
 *
 *
 */
public class AppTest1 {

    public static void main(String[] args) {
        ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("applicationContext.xml");
        BookDao bookDao = (BookDao) context.getBean("bookDao");
        BookService bookService = (BookService) context.getBean("bookServiceImpl");
        bookDao.save();
        bookService.save();

    }

}
